
#include "qlibc/QData.h"
#include "log/Logging.h"
#include "common/httpUtil.h"
#include <thread>

int main(int argc, char* argv[]){
    while(true){
        qlibc::QData request, response;
        request.loadFromFile("/home/lhy/smarthome/edge_rk3308/software/query_config_ble_synergy_sites/unit/test/powerOn.json");
        httpUtil::sitePostRequest("192.168.43.45", 9001, request, response);

        std::this_thread::sleep_for(std::chrono::seconds(1));
        request.loadFromFile("/home/lhy/smarthome/edge_rk3308/software/query_config_ble_synergy_sites/unit/test/powerOff.json");
        httpUtil::sitePostRequest("192.168.43.45", 9001, request, response);
        std::this_thread::sleep_for(std::chrono::seconds(1));
    }
    return 0;
}
























